function Rest()
{
	if !${Me.InCombat} && !${Target(exists)} && ${VirtualState.Equal[ROAM]} || ${VirtualState.Equal[IDLE]}
	{
		call Downtime
		call Prep
		if ${Math.Calc[${Me.Health} / ${Me.MaxHealth} * 100]} < 85.000000 || ${Math.Calc[${Me.Power} / ${Me.MaxPower} * 100]} < 50.000000
		{
			call Sit
			while ${Math.Calc[${Me.Health} / ${Me.MaxHealth} * 100]} < 85.000000 || ${Math.Calc[${Me.Power} / ${Me.MaxPower} * 100]} < 50.000000
			{
				waitframe
			}
		}
		call Stand
	}
}
function Sit()
{
	if !${Me.IsSitting}
	{
		E "Sitting"
		EQ2Execute /sit
		while !${Me.IsSitting}
		{
			waitframe
		}
	}
}
function Stand()
{
	if ${Me.IsSitting}
	{
		E "Standing"
		EQ2Execute /stand
		while ${Me.IsSitting}
		{
			waitframe
		}
	}
}